package bb.lanxing.model.routebook;

import com.github.mikephil.charting.utils.Utils;
import com.google.gson.annotations.Expose;
//import com.huawei.hms.network.embedded.C4167d1;

import java.util.UUID;

import bb.lanxing.model.map.GeoPoint;
import bb.lanxing.lib.kt.model.geo.IGeoPoint;
import bb.lanxing.util.LatLngFormat;
import kotlin.jvm.internal.DefaultConstructorMarker;
import kotlin.jvm.internal.Intrinsics;

public final class RouteBookWayPoint {
    private String address;
    private String content;
    private double distance;
    @Expose(deserialize = false, serialize = true)

    private long id;
    private double latitude;
    private double longitude;
    private int original_index;
    @Expose(deserialize = false, serialize = true)
    private long route_id;
    @Expose(deserialize = false, serialize = true)
    private boolean selected;
    @Expose(deserialize = false, serialize = true)
    private RouteBookWayPointState state;
    private String title;
    private int type;
    private boolean userSavedTitle;
    @Expose(deserialize = false, serialize = true)
    private UUID uuid;
    private boolean visible;

    public RouteBookWayPoint() {
        this(0L, 0L, 0, 0, Utils.DOUBLE_EPSILON, Utils.DOUBLE_EPSILON, null, false, null, null, Utils.DOUBLE_EPSILON, false, null, false, null, 32767, null);
    }

    public final long component1() {
        return this.id;
    }

    public final String component10() {
        return this.address;
    }

    public final double component11() {
        return this.distance;
    }

    public final boolean component12() {
        return this.visible;
    }

    public final RouteBookWayPointState component13() {
        return this.state;
    }

    public final boolean component14() {
        return this.selected;
    }

    public final UUID component15() {
        return this.uuid;
    }

    public final long component2() {
        return this.route_id;
    }

    public final int component3() {
        return this.original_index;
    }

    public final int component4() {
        return this.type;
    }

    public final double component5() {
        return this.latitude;
    }

    public final double component6() {
        return this.longitude;
    }

    public final String component7() {
        return this.title;
    }

    public final boolean component8() {
        return this.userSavedTitle;
    }

    public final String component9() {
        return this.content;
    }

    public final RouteBookWayPoint copy(long j, long j2, int i, int i2, double d, double d2, String title, boolean z, String content, String address, double d3, boolean z2, RouteBookWayPointState state, boolean z3, UUID uuid) {
        Intrinsics.checkNotNullParameter(title, "title");
        Intrinsics.checkNotNullParameter(content, "content");
        Intrinsics.checkNotNullParameter(address, "address");
        Intrinsics.checkNotNullParameter(state, "state");
        Intrinsics.checkNotNullParameter(uuid, "uuid");
        return new RouteBookWayPoint(j, j2, i, i2, d, d2, title, z, content, address, d3, z2, state, z3, uuid);
    }

    public String toString() {
        return "RouteBookWayPoint(id=" + this.id + ", route_id=" + this.route_id + ", original_index=" + this.original_index + ", type=" + this.type + ", latitude=" + this.latitude + ", longitude=" + this.longitude + ", title=" + this.title + ", userSavedTitle=" + this.userSavedTitle + ", content=" + this.content + ", address=" + this.address + ", distance=" + this.distance + ", visible=" + this.visible + ", state=" + this.state + ", selected=" + this.selected + ", uuid=" + this.uuid + ')';
    }

    public RouteBookWayPoint(long j, long j2, int i, int i2, double d, double d2, String title, boolean z, String content, String address, double d3, boolean z2, RouteBookWayPointState state, boolean z3, UUID uuid) {
        Intrinsics.checkNotNullParameter(title, "title");
        Intrinsics.checkNotNullParameter(content, "content");
        Intrinsics.checkNotNullParameter(address, "address");
        Intrinsics.checkNotNullParameter(state, "state");
        Intrinsics.checkNotNullParameter(uuid, "uuid");
        this.id = j;
        this.route_id = j2;
        this.original_index = i;
        this.type = i2;
        this.latitude = d;
        this.longitude = d2;
        this.title = title;
        this.userSavedTitle = z;
        this.content = content;
        this.address = address;
        this.distance = d3;
        this.visible = z2;
        this.state = state;
        this.selected = z3;
        this.uuid = uuid;
    }

    public final long getId() {
        return this.id;
    }

    public final void setId(long j) {
        this.id = j;
    }

    public final long getRoute_id() {
        return this.route_id;
    }

    public final void setRoute_id(long j) {
        this.route_id = j;
    }

    public final int getOriginal_index() {
        return this.original_index;
    }

    public final void setOriginal_index(int i) {
        this.original_index = i;
    }

    public /* synthetic */ RouteBookWayPoint(long j, long j2, int i, int i2, double d, double d2, String str, boolean z, String str2, String str3, double d3, boolean z2, RouteBookWayPointState routeBookWayPointState, boolean z3, UUID uuid, int i3, DefaultConstructorMarker defaultConstructorMarker) {
//        this(r4, r2, r1, r7, r11, r13, r8, r6, r9, r15, r16, r42, r18, r19, r0);
        boolean z4;
        UUID uuid2;
        long j3 = (i3 & 1) != 0 ? 0L : j;
        long j4 = (i3 & 2) == 0 ? j2 : 0L;
        int i4 = (i3 & 4) != 0 ? 0 : i;
        int type = (i3 & 8) != 0 ? RouteBookWayPointType.TYPE_NAVI.getType() : i2;
        double d4 = (i3 & 16) != 0 ? Utils.DOUBLE_EPSILON : d;
        double d5 = (i3 & 32) != 0 ? Utils.DOUBLE_EPSILON : d2;
        String str4 = (i3 & 64) != 0 ? "" : str;
        boolean z5 = (i3 & 128) != 0 ? false : z;
        String str5 = (i3 & 256) != 0 ? "" : str2;
        String str6 = (i3 & 512) == 0 ? str3 : "";
        double d6 = (i3 & 1024) != 0 ? Utils.DOUBLE_EPSILON : d3;
        boolean z6 = (i3 & 2048) != 0 ? true : z2;
        RouteBookWayPointState routeBookWayPointState2 = (i3 & 4096) != 0 ? RouteBookWayPointState.TYPE_INIT : routeBookWayPointState;
        boolean z7 = (i3 & 8192) != 0 ? false : z3;
        if ((i3 & 16384) != 0) {
            uuid2 = UUID.randomUUID();
            z4 = z7;
            Intrinsics.checkNotNullExpressionValue(uuid2, "randomUUID()");
        } else {
            z4 = z7;
            uuid2 = uuid;
        }
    }

    public final int getType() {
        return this.type;
    }

    public final void setType(int i) {
        this.type = i;
    }

    public final double getLatitude() {
        return this.latitude;
    }

    public final void setLatitude(double d) {
        this.latitude = d;
    }

    public final double getLongitude() {
        return this.longitude;
    }

    public final void setLongitude(double d) {
        this.longitude = d;
    }

    public final String getTitle() {
        return this.title;
    }

    public final void setTitle(String str) {
        Intrinsics.checkNotNullParameter(str, "<set-?>");
        this.title = str;
    }

    public final boolean getUserSavedTitle() {
        return this.userSavedTitle;
    }

    public final void setUserSavedTitle(boolean z) {
        this.userSavedTitle = z;
    }

    public final String getContent() {
        return this.content;
    }

    public final void setContent(String str) {
        Intrinsics.checkNotNullParameter(str, "<set-?>");
        this.content = str;
    }

    public final String getAddress() {
        return this.address;
    }

    public final void setAddress(String str) {
        Intrinsics.checkNotNullParameter(str, "<set-?>");
        this.address = str;
    }

    public final double getDistance() {
        return this.distance;
    }

    public final void setDistance(double d) {
        this.distance = d;
    }

    public final boolean getVisible() {
        return this.visible;
    }

    public final void setVisible(boolean z) {
        this.visible = z;
    }

    public final RouteBookWayPointState getState() {
        return this.state;
    }

    public final void setState(RouteBookWayPointState routeBookWayPointState) {
        Intrinsics.checkNotNullParameter(routeBookWayPointState, "<set-?>");
        this.state = routeBookWayPointState;
    }

    public final boolean getSelected() {
        return this.selected;
    }

    public final void setSelected(boolean z) {
        this.selected = z;
    }

    public final UUID getUuid() {
        return this.uuid;
    }

    public final void setUuid(UUID uuid) {
        Intrinsics.checkNotNullParameter(uuid, "<set-?>");
        this.uuid = uuid;
    }

    public final String getTitleOrLocationString() {
        if (this.title.length() == 0) {
            String formatToLocationString = LatLngFormat.formatToLocationString(this.latitude, this.longitude);
            Intrinsics.checkNotNullExpressionValue(formatToLocationString, "{\n            LatLngForm…ude, longitude)\n        }");
            return formatToLocationString;
        }
        return this.title;
    }

    public final IGeoPoint convertIGeoPoint() {
        GeoPoint fromCommon = GeoPoint.fromCommon(this.latitude, this.longitude);
        Intrinsics.checkNotNullExpressionValue(fromCommon, "fromCommon(latitude, longitude)");
        return (IGeoPoint) fromCommon;
    }

    public boolean equals(Object obj) {
        if (obj instanceof RouteBookWayPoint) {
            return Intrinsics.areEqual(((RouteBookWayPoint) obj).uuid, this.uuid);
        }
        return super.equals(obj);
    }

    public int hashCode() {
        return this.uuid.hashCode();
    }
}